package com.copa.module.order.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.copa.domain.PageVo;
import com.copa.domain.ResponseDto;
import com.copa.module.goods.domain.dto.CategoryDto;
import com.copa.module.order.domain.dto.OrderDetailDto;
import com.copa.module.order.domain.dto.OrderListDto;
import com.copa.module.order.domain.vo.OrderApplyVo;
import com.copa.module.order.domain.vo.OrderCancelVo;
import com.copa.module.order.domain.vo.OrderConfirmVo;
import com.copa.module.order.domain.vo.OrderListVo;

import java.math.BigDecimal;
import java.time.LocalDate;

/**
 * @author copa
 * @createDate 2021-01-09 15:33
 * @function
 */
public interface OrderService {
    ResponseDto<IPage<OrderListDto>> list(OrderListVo orderListVo);

    ResponseDto<OrderDetailDto> detail(Long orderId);

    ResponseDto<String> confirmOrder(OrderConfirmVo orderConfirmVo);

    ResponseDto<String> cancelOrder(OrderCancelVo orderCancelVo);

    ResponseDto<String> applyRefundOrder(OrderApplyVo orderApplyVo);

    Long findAddTotalOrderNumByTime(LocalDate now, LocalDate yesterday);

    Long findAddOrderGoodsNumByTime(LocalDate now, LocalDate yesterday);

    Long findAddPayTotalOrderNumByTime(LocalDate now, LocalDate yesterday);

    Long findAddPayOrderGoodsNumByTime(LocalDate now, LocalDate yesterday);

    Long findRefundOrderGoodsNumByTime(LocalDate now, LocalDate yesterday);

    BigDecimal findIncomeByTime(LocalDate now, LocalDate yesterday);

    BigDecimal findRefundByTime(LocalDate now, LocalDate yesterday);

    Long findAddSaleGoodsNumByTime(LocalDate now, LocalDate yesterday);

    Long findRefundSaleGoodsNumByTime(LocalDate now, LocalDate yesterday);
}
